<?php 
    global $dir_tpl, $tb_fix, $temp, $anyDB;  
    $shopurl = get_data('shop_url','config_values');
    $temp->assign("shopurl",$shopurl);  
    $temp->assign( 'base_tpl', "".$dir_tpl."" ); 
    $sql = "select * from ".$tb_fix."_galery ORDER BY RAND( )";
    $query = $anyDB->query($sql);
    $arr = $anyDB->getAll($query);
    foreach ($arr as $key => $value){
        $arr[$key]['title_conver'] = convertText($value['gale_name']); 
    }
$temp->assign('galery',$arr);
$temp->display("$dir_tpl/blocks/trong_gallery/index.mct"); 
?> 
